package com.yuyu.demo.spring4.factory;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import com.yuyu.demo.spring4.beans.Car;

public class TestForFactory {
	public static void main(String[] args) {
		ApplicationContext applicationContext = new ClassPathXmlApplicationContext("appFactory.xml");
		Car car = (Car)applicationContext.getBean("car2");
		
		System.out.println(car.toString());
	}
}
